<!DOCTYPE html>
<html>
	<?php echo $head; ?>
	<body>
		<!-- Home -->
		<div data-role="page" id="page1">
			<div data-theme="b" data-role="header" data-id="head" data-position="fixed">
				<a href="<?php echo $this->input->server("REDIRECT_URL");?>" data-role="button" data-direction="reverse" data-transition="flow" data-rel="back" data-icon="arrow-left" data-iconpos="left" class="ui-btn-left">
					Back
				</a>
				<h3>
					Hasil Pencarian
				</h3>
			</div>
			<div data-role="content">
				<ul data-role="listview" data-inset="true">
					<li><strong>Stasiun Keberangkatan :</strong> Stasiun <?php echo $berangkat[0]->Nama_Stasiun; ?></li>
					<li><strong>Stasiun Tujuan :</strong> Stasiun <?php echo $tujuan[0]->Nama_Stasiun; ?></li>
					<li><strong>Waktu Keberangkatan :</strong> <?php echo $this->input->get('waktuberangkat'); ?></li>
					<?php if($this->input->get('waktuberangkat')): ?>
					<li><strong>Sampai Sebelum :</strong> <?php echo $this->input->get('waktuberangkat'); ?></li>
					<? endif; ?>
				</ul>
				<ul data-role="listview" data-inset="true" data-divider-theme="a" data-filter="true" data-filter-placeholder="Cari jadwal...">
					<?php if($hasil != NULL): ?>
					<?php foreach($hasil as $row): ?>
					<li data-theme="a" data-role="fieldcontain">
						<a href="<?php echo site_url('pencarian/detail').'?id='.$row->id.'&asal='.$this->input->get('keberangkatan').'&tujuan='.$this->input->get('tujuan'); ?>" data-transition="flow">
						<h3>No KRL : <?php echo $row->no_krl;?></h3>
						<p><strong>Kelas :</strong> <?php echo $row->Kelas; ?></p>
						<p class="ui-li-aside">
							<strong>Jam berangkat : </strong><?php echo $row->jam_ber;?><br/>
							<strong>Jam kedatangan : </strong><?php echo $row->jam_dat;?>
						</p>
						</a>
					</li>
					<?php endforeach; ?>
					<?php else: ?>
					<li data-theme="a" data-role="fieldcontain">
						<h3>Data tidak ditemukan</h3>
					</li>
					<?php endif; ?>
				</ul>	
			</div>
			<?php echo $foot;?>
		</div>
		<script>
			//App custom javascript
		</script>
	</body>
</html>
